<?php
require('config.php');
		$get_num=$_REQUEST['get_num'];
		$yiji_id=$_REQUEST['yiji_id'];
		$erji_id=$_REQUEST['erji_id'];
		$shop_id=$_REQUEST['shop_id'];
		if($get_num==1)
		{
			$sql="select goodsName,goodsImg,goodsId,shopPrice from `".$oto."_goods` where `shopCatId1`='$yiji_id' and `isSale`=1 and `isGroup`=0 and shopId='{$shop_id}' and goodsFlag='1'";
		}
		else if($get_num==2)
		{
			$sql="select goodsName,goodsImg,goodsId,shopPrice from `".$oto."_goods` where `shopCatId1`='$yiji_id' and `shopCatId2`='$erji_id' and `isSale`=1 and `isGroup`=0 and shopId='{$shop_id}' and goodsFlag='1'";
		}
		$result=$db->query($sql);
		while($row=$result->fetch_assoc()){
			$person_info[]=$row;//将取得的所有数据赋值给person_info数组
		}
		if(isset($person_info))
		{
			echo json_encode($person_info);
		}
		else echo '[]';
		
?>